﻿import request from '/@/utils/request';
enum Api {
  AddRoadMaintenance = '/api/roadMaintenance/add',
  DeleteRoadMaintenance = '/api/roadMaintenance/delete',
  UpdateRoadMaintenance = '/api/roadMaintenance/update',
  PageRoadMaintenance = '/api/roadMaintenance/page',
  DetailRoadMaintenance = '/api/roadMaintenance/detail',
}

// 增加养护历史数据
export const addRoadMaintenance = (params?: any) =>
	request({
		url: Api.AddRoadMaintenance,
		method: 'post',
		data: params,
	});

// 删除养护历史数据
export const deleteRoadMaintenance = (params?: any) => 
	request({
			url: Api.DeleteRoadMaintenance,
			method: 'post',
			data: params,
		});

// 编辑养护历史数据
export const updateRoadMaintenance = (params?: any) => 
	request({
			url: Api.UpdateRoadMaintenance,
			method: 'post',
			data: params,
		});

// 分页查询养护历史数据
export const pageRoadMaintenance = (params?: any) => 
	request({
			url: Api.PageRoadMaintenance,
			method: 'post',
			data: params,
		});

// 详情养护历史数据
export const detailRoadMaintenance = (id: any) => 
	request({
			url: Api.DetailRoadMaintenance,
			method: 'get',
			data: { id },
		});


